package com.example.oom;

import java.text.SimpleDateFormat;
import java.time.LocalDate;
import java.time.ZoneId;
import java.util.ArrayList;
import java.util.Date;
import java.util.HashSet;

public class Test {

    public static void main(String[] args) {
        ArrayList<Integer> objects = new ArrayList<>();
        for (int i = 0; i < 999999L; i++) {
            objects.add(i);
        }
        final int[] i = {0};
        objects.forEach(e->{
            i[0] = i[0] + e;
        });
        System.out.println(i[0]);
    }

}
